<?php 
include '/../includes/mensagens.php';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    
<head>
    <? include "/../includes/head.inc" ?>  

    </head>
      
    <body>
    <!-- Carragando animação -->
    <div id="qLoverl"></div>
    <div id="qLbar"></div>
        
    <div id="header">

        <? include "/../includes/cabecalho.inc" ?>  

    </div><!-- Fim #header -->

    <div id="wrapper">

        <!--Responsive navigation button-->  
        <div class="resBtn">
            <a href="#"><span class="icon16 minia-icon-list-3"></span></a>
        </div>
        
         <? include "/../includes/menuLateral.inc" ?>  
        
        <!--Body content-->
        <div id="content" class="clearfix">
            <div class="contentwrapper"><!--Content wrapper-->

                <div class="heading">

                    <h3>Feiras</h3>                    

                    <div class="resBtnSearch">
                        <a href="#"><span class="icon16 icomoon-icon-search-3"></span></a>
                    </div>

                    <div class="search">

                        <form id="searchform" action="">
                            <input type="text" id="tipue_search_input" class="top-search" placeholder="Pesquise" />
                            <input type="submit" id="tipue_search_button" class="search-btn" value=""/>
                        </form>
                
                    </div><!-- Fim search -->
                    
                    <ul class="breadcrumb">
                        <li>Você está aqui:</li>
                        <li>
                            <a href="<?= BASE?>" class="tip" title="Clique aqui para ir para página inicial">
                                <span class="icon16 "><img src="<?= BASE?>/webfiles/css/img/home3.png" /></span>
                            </a> 
                            <span class="divider">
                                <span class="icon16 "><img src="<?= BASE?>/webfiles/css/img/seta.png" /></span>
                            </span>
                        </li>
                        <li class="active">Feiras</li>
                    </ul>

                </div><!-- Fim .heading-->

                <!--Corpo da página  -->
                <!-- tudo deverá ser construído a partir daqui -->
               <div class="row-fluid">
                
                        <div class="span12">
                            
                             <div class="centerContent">
                  
                            <ul class="bigBtnIcon">
                                
                                <li>
                                    <a href="<?= BASE?>/feiras/artesao/id/<? if ( isset($view_feira_lista[0]["ID_FEIRA"])){ echo $view_feira_lista[0]["ID_FEIRA"];} ?>" title="Clique aqui para adicionar mais artesões." class="tipB">
                                        <span class="icon icomoon-icon-plus2"></span>
                                        <span class="txt">Adicionar</span>
                                    </a>
                                </li>
                                
                                <li>
                                    <a href="#" title="Clique aqui para imprimir." class="tipB">
                                        <span class="icon icomoon-icon-users-2"></span>
                                        <span class="txt">Imprimir</span>
                                    </a>
                                </li>
                                
                              
                            </ul>
                                  <?php if(isset($_SESSION['msg'])){
                                            echo "<div class='alert alert-success'><button type='button' class='close' data-dismiss='alert'>&times;</button>"; 
                                             echo "<strong>" .$_SESSION['msg']." </strong></div>";
                                        } 
                                  ?>
                        </div>
                       
                  
                            <div class="marginB10"></div>

                            <div class="box gradient">

                                <div class="title">
                                    <h4>
                                        <span><? if (isset($view_feira_lista[0]["NOME_FEIRA"])){
                                                echo $view_feira_lista[0]["NOME_FEIRA"]; }?></span>
                                    </h4>
                                </div>
                                <div class="content noPad clearfix">
                                    <table cellpadding="0" cellspacing="0" border="0" class="responsive dynamicTable display table table-bordered" width="100%">
                                        <thead>
                                            <tr>
                                                <th>Cpf</th>
                                                <th>Nome</th>
                                                <th>Opções</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <?php 
                                            if (count($view_feira_lista) >= 2){
                                            foreach($view_feira_lista as $dados): ?>
                                            <tr class="odd gradeX">
                                                <td><?php echo $dados["CPF"]; ?></td>
                                                <td><?php echo $dados["NOME"]; ?></td>
                                                <td><a class="tip" onclick="confirmExclusao()" href="<?= BASE?>/feiras/deleta_artesao/id/<? echo $dados["ID_FEIRA"]; ?>/cpf/<? echo $dados["CPF"]; ?>" title="Clique aqui para deletar o registro"><img class="btn" src="<?= BASE?>/webfiles/css/img/minus-button.png" /></a></td>
                                            </tr>
                                            <?php endforeach; }?>
                                           
                                            
                                        </tbody>
                                       
                                    </table>
                                </div>

                            </div><!-- Fim .box -->

                        </div><!-- Fim .span12 -->

                    </div><!-- Fim .row-fluid -->


                </div><!--Fim corpo da página -->

                

            
            </div><!-- Fim contentwrapper -->
        </div><!-- Fim #content -->
    
    </div><!-- Fim #wrapper -->
    
    <!--  javascript
    ================================================== -->
      <?include "/../includes/javascript.inc" ?>  
    
  
    </body>

</html>


